<?php

/*
	任务列表（工作人员）
*/
defined('BY_JYA') or exit('error');
$_RQ['op']=$_RQ['op']?$_RQ['op']:'get';
$return=array();
if($_RQ['op']=='get'){
	$renwus = array();
	$renwus['all'] = pdo_count('jy_workline_task',array('uniacid'=>$_SESSION['uniacid'],'setmid'=>$_SESSION['uid']));
	$renwus['day'] = pdo_count('jy_workline_task',array('uniacid'=>$_SESSION['uniacid'],'setmid'=>$_SESSION['uid'],'createtime >'=>strtotime(date('ymd'))));

	$all = pdo_getall('jy_workline_task',array('uniacid'=>$_SESSION['uniacid'],'setmid'=>$_SESSION['uid']),'credit');
	$alljf=0;
	foreach($all as &$ajf){
			$alljf +=$ajf['credit'];
	}
	$day = pdo_getall('jy_workline_task',array('uniacid'=>$_SESSION['uniacid'],'setmid'=>$_SESSION['uid'],'createtime >'=>strtotime(date('ymd'))),'credit');
	$dayjf=0;
	foreach($day as &$djf){
			$dayjf +=$djf['credit'];
	}
	$return['jifen']=array('dayjf'=>$dayjf,'alljf'=>$alljf);
	$return['renwus']=$renwus;
	exi($return);
}
